﻿using Ninject.Core.Parameters;
using TestBat.IViewModels.Factories;
using TestBat.IViewModels.Workspaces.Tasks;
using TestBat.ServiceLocator;

namespace TestBat.ViewModels.Factories
{
    public class TaskTreeViewModelFactory : ITaskTreeViewModelFactory
    {
        public ITaskTreeViewModel Create(bool readOnly)
        {
            return (readOnly) ? DefaultServiceLocator.Get<ITaskTreeViewModel>(With.Parameters.Variable("readOnly", true)) : DefaultServiceLocator.Get<ITaskTreeViewModel>();
        }
    }
}
